﻿<%@ Page Title="Ofertas" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="Ofertas.aspx.vb" Inherits="Egresados_Ofertas_Ofertas" %>

<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" Runat="Server">

    <style type="text/css">
        .style1
        {
            text-align:center;
            text-transform:uppercase;
            }
    </style>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" Runat="Server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <asp:FormView ID="FormView1" runat="server" BorderColor="Black" 
                BorderStyle="None" BorderWidth="1px" CellPadding="4" 
                DataSourceID="ObjEgresados" FooterText=" " ForeColor="#333333" 
                Width="983px">
                <EditRowStyle BackColor="#999999" />
                <EmptyDataTemplate>
                    <table style="width: 100%;">
                        <tr>
                            <td class="style1">
                                <asp:Image ID="Image1" runat="server" ImageUrl="~/Imagenes/dialog_warning.png" 
                                    style="text-align: center" />
                            </td>
                        </tr>
                        <tr>
                            <td class="style1">
                                El Usuario actual no es Egresado. Si lo es acerquese a la oficina de Bienestar 
                                Universitario para su registro.</td>
                        </tr>
                        <tr>
                            <td class="style1">
                                &nbsp;</td>
                        </tr>
                    </table>
                </EmptyDataTemplate>
                <FooterStyle BackColor="#2e4c0e" Font-Bold="True" ForeColor="White" />
                <HeaderStyle BackColor="#2e4c0e" Font-Bold="True" ForeColor="White" />
                <HeaderTemplate>
                    <h1 style="text-align:center; color:White; font-size:1.5em; font-weight:bold;">
                        MIS OFERTAS
                    </h1>
                </HeaderTemplate>
                <ItemTemplate>
                    <table width="100%">
                        <thead>
                            <tr>
                                <td colspan="3" style="color:White; text-align:center;">
                                    Datos de la Empresa</td>
                                        </td>
                                    </td>
                                </td>
                            </tr>
                        </thead>
                        <thead>
                            <tr>
                                <th style="text-align:center;">
                                    Tipo de Documento</td>
                                    <th style="text-align:center;">
                                        Documento</td>
                                        <th style="text-align:center;">
                                            Nombre o Razon Social</td>
                                        </th>
                                    </th>
                                </th>
                            </tr>
                        </thead>
                        <tr>
                            <th class="style2">
                                <asp:Label ID="Label1" runat="server" Text='<%# Eval("Nom_Tip_ID") %>'></asp:Label>
                            </th>
                            <th class="style2">
                                <asp:Label ID="Label2" runat="server" Text='<%# Eval("Identificacion") %>'></asp:Label>
                            </th>
                            <th class="style4">
                                <asp:Label ID="Label3" runat="server" Text='<%# Eval("Nombre") %>'></asp:Label>
                            </th>
                        </tr>
                        
                    </table>
                </ItemTemplate>
                <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            </asp:FormView>
            <asp:ObjectDataSource ID="ObjEgresados" runat="server" 
                OldValuesParameterFormatString="original_{0}" SelectMethod="GetEmpresa" 
                TypeName="Empresas"></asp:ObjectDataSource>
            <asp:MultiView ID="MultiView1" runat="server" ActiveViewIndex="1">
                <asp:View ID="View1" runat="server">
                     <asp:ValidationSummary ID="ValidationSummary1" runat="server" 
                         ValidationGroup="Guardar" CssClass="validacion" />
                     <table class="Table" style="width:100%;">
                        <thead>
                            <tr>
                                <td class="style1">
                                    <asp:Label ID="LbOper" runat="server"></asp:Label>
                                </td>
                            </tr>
                        </thead>
                        <thead>
                            <tr>
                                <th class="style1">
                                    Titulo</th>
                            </tr>
                        </thead>
                        <tr>
                            <th class="style2">
                                <asp:TextBox ID="TxtTitulo" runat="server" Height="22px" TextMode="SingleLine" 
                                    Width="516px" CssClass="style1"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                                    ControlToValidate="TxtTitulo" 
                                    ErrorMessage="Escriba el titulo de la Oferta" ForeColor="Red" 
                                    ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                            </th>
                        </tr>
                        <thead>
                            <tr>
                                <th class="style1">
                                    Descripcion</th>
                            </tr>
                        </thead>
                        <tr>
                            <th class="style2">
                                <asp:TextBox ID="TxtDesc" runat="server" Height="119px" TextMode="MultiLine" 
                                    Width="900px"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                    ControlToValidate="TxtDesc" 
                                    ErrorMessage="Escriba la descripción de la Oferta" ForeColor="Red" 
                                    ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                            </th>
                        </tr>
                        <thead>
                         </thead>
                         <thead>
                         </thead>
                        
                    </table>
                     <table class="Table" style="width:100%;">
                         <thead>
                         </thead>
                         <thead>
                             <tr>
                                 <th class="style5">
                                     TIPO DE EMPLEO<th class="style5">
                                         duración<th class="style5">
                                             convenio<th class="style7">
                                                 AUXILIO<th class="style3">
                                                     fecha de inicio</th>
                                             </th>
                                         </th>
                                         <th class="style3">
                                             vacantes</th>
                                     </th>
                                 </th>
                             </tr>
                         </thead>
                         <tr>
                             <th class="style6">
                                 <asp:DropDownList ID="CmbTipEmpleo" runat="server" DataSourceID="ObjTipEmp" 
                                     DataTextField="Nombre" DataValueField="Id">
                                 </asp:DropDownList>
                                 <asp:ObjectDataSource ID="ObjTipEmp" runat="server" 
                                     OldValuesParameterFormatString="original_{0}" SelectMethod="GetRecords" 
                                     TypeName="Tipo_Empleos"></asp:ObjectDataSource>
                             </th>
                             <th class="style6">
                                 <asp:TextBox ID="TxtDur" runat="server"></asp:TextBox>
                                 <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" 
                                     ControlToValidate="TxtDur" ErrorMessage="Escriba la Duración de la Practica" 
                                     ForeColor="Red" ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                             </th>
                             <th class="style6">
                                 <asp:DropDownList ID="CmbConvenio" runat="server" AutoPostBack="True">
                                     <asp:ListItem Value="CA">Contrato Aprendizaje</asp:ListItem>
                                     <asp:ListItem Value="PA">Pasantias</asp:ListItem>
                                 </asp:DropDownList>
                             </th>
                             <th class="style8">
                                 <telerik:RadNumericTextBox ID="TxtSal" Runat="server" 
                                     Culture="es-CO" Type="Currency" Width="125px" DataType="System.Decimal">
                                 </telerik:RadNumericTextBox>
                             </th>
                             <th class="style4">
                                 <asp:TextBox ID="TxtFecIni" runat="server"></asp:TextBox>
                                 <ajaxToolkit:CalendarExtender 
                                  Format="dd/MM/yyyy" 
                                  ID="C1" 
                                  runat="server" 
                                  TargetControlID="TxtFecIni">
                                 </ajaxToolkit:CalendarExtender>
                             </th>
                             <th class="style4">
                                 <telerik:RadNumericTextBox ID="TxtVac" Runat="server">
                                 </telerik:RadNumericTextBox>
                                 <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                                     ControlToValidate="TxtVac" ErrorMessage="Escriba el número de vacantes" 
                                     ForeColor="Red" ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                             </th>
                         </tr>
                         <thead>
                         <tr>
                             <th class="style6" colspan="6">
                                 las ofertas de empleo son clasificadas por programa academico. Por favor 
                                 seleccione los programas en que mejor se podría clasificar su oferta de empleo.</th>
                         </tr>
                         </thead>
                         <tr>
                             <th class="style2" colspan="6">
                             <asp:DataList ID="DataList1" runat="server" CellPadding="4" CellSpacing="5" CssClass="txt"
                        DataKeyField="Id" DataSourceID="ObjProg" ForeColor="#333333"
                        RepeatColumns="3">
                        <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <AlternatingItemStyle BackColor="White" ForeColor="#2e4c0e" />
                        <ItemStyle BackColor="#cff4c7" ForeColor="#333333" />
                        <SelectedItemStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                        <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <ItemTemplate>
                            <asp:CheckBox ID="chknomprog" runat="server" Checked='<%# eval("est") %>' Text='<%# Eval("NOM_PROGRAMA") %>' />
                            <asp:TextBox ID="txtcodprog" runat="server" Text='<%# Eval("Id") %>' Visible="False"
                                Width="197px"></asp:TextBox>
                            <asp:TextBox ID="TXTCODFAC" runat="server" Text='<%# Eval("COD_FACULTAD") %>' Visible="False"
                                Width="197px"></asp:TextBox>
                        </ItemTemplate>
                    </asp:DataList>
                                 <asp:ObjectDataSource ID="ObjProg" runat="server" 
                                     OldValuesParameterFormatString="original_{0}" SelectMethod="GetOferProg" 
                                     TypeName="Ofertas">
                                     <SelectParameters>
                                         <asp:ControlParameter ControlID="HfPK" Name="ID_OFERTA" PropertyName="Value" 
                                             Type="String" />
                                     </SelectParameters>
                                 </asp:ObjectDataSource>
                                 </th>
                         </tr>
                         
                         <tr>
                             <td class="style2" colspan="6">
                                 &nbsp;</td>
                         </tr>
                         
                         <tr>
                             <th class="style6" colspan="6">
                                 <asp:ImageButton ID="ImageButton1" runat="server" Height="32px" 
                                     ImageUrl="~/Imagenes/floppy_disk_green.png" ToolTip="Guardar" 
                                     ValidationGroup="Guardar" Width="32px" />
                                 <asp:ImageButton ID="ImageButton2" runat="server" Height="32px" 
                                     ImageUrl="~/Imagenes/undo_.png" ToolTip="Volver" Width="32px" />
                             </th>
                         </tr>
                         <thead>
                         </thead>
                         <thead>
                         </thead>
                     </table>
                     <br />
                </asp:View>
                <asp:View ID="View2" runat="server">
                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
                        CellPadding="4" DataKeyNames="Id_Oferta" DataSourceID="ObjFacultades" 
                        ForeColor="#333333" GridLines="None" BorderColor="Black" 
                        BorderStyle="None" BorderWidth="1px" SkinID="gridView" AllowPaging="True" 
                        PageSize="5" Width="983px" >
                        <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        <Columns>
                            <%--<asp:TemplateField>
                            <ItemTemplate>
                                <asp:Label ID="LbNumero" runat="server" Text="Label"></asp:Label>
                            </ItemTemplate>
                            </asp:TemplateField>--%>
                            <asp:BoundField DataField="Titulo" HeaderText="Titulo" />
                            <asp:BoundField DataField="Descripcion" HeaderText="Descripción" >                             
                               <ItemStyle Width="150px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Nom_Tip_Empleo" 
                                HeaderText="Tipo de Empleo" />
                                <asp:BoundField DataField="Duracion" HeaderText="Duración" />
                            <asp:BoundField DataField="NomConvenio" HeaderText="Convenio" />
                            
                            <asp:BoundField DataField="Salario" DataFormatString="{0:c}" 
                                HeaderText="Auxilio"></asp:BoundField>
                            <asp:BoundField DataField="Comienzo" 
                                HeaderText="Fecha de Inicio" DataFormatString="{0:d}" />
                            <asp:BoundField DataField="Vacantes" HeaderText="Vacantes" />
                            <asp:BoundField DataField="Nom_Estado" HeaderText="Estado" />
                            <asp:ButtonField ButtonType="Image" CommandName="Editar" 
                                ImageUrl="~/Imagenes/Editar.png" Text="Editar" ItemStyle-Width="16" 
                                ItemStyle-Height="16" >                      
                            <ItemStyle Height="16px" Width="16px" />
                            </asp:ButtonField>
                            <asp:ButtonField ButtonType="Image" CommandName="Eliminar" Text="Eliminar" 
                                ImageUrl="~/Imagenes/remove.png" />
                        </Columns>
                        
                        </asp:GridView>
                      <table align="center" style="width:100%;">
                          <tr>
                              <th class="style9">
                                  &nbsp;</th>
                              <th>
                                  <asp:ImageButton ID="ImageButton3" runat="server" 
                                      ImageUrl="~/Imagenes/document_new.png" />
                              </th>
                              <th>
                                  &nbsp;</th>
                          </tr>
                    </table>
                      <br />
                    <asp:ObjectDataSource ID="ObjFacultades" runat="server" 
                        SelectMethod="GetxEmpresa" TypeName="Ofertas" 
                        OldValuesParameterFormatString="original_{0}">
                    </asp:ObjectDataSource>
                    <asp:HiddenField ID="HfOper" runat="server" />
                    <asp:HiddenField ID="HfPK" runat="server" />
                    <br />
                </asp:View>
            </asp:MultiView>
            <br />
        </ContentTemplate>
    </asp:UpdatePanel>
<asp:UpdatePanel ID="UpdatePanel2" runat="server">
            <ContentTemplate>
             </ajaxToolkit:ModalPopupExtender>
             <asp:Button ID="btn_Target" runat="server" style="display:none" />
                    <asp:Button style="DISPLAY: none" id="hiddenTargetControlForModalPopup" runat="server" __designer:wfdid="w98"></asp:Button> 
            <ajaxToolkit:ModalPopupExtender 
            id="ModalPopup" 
            runat="server" 
            TargetControlID="hiddenTargetControlForModalPopup" 
            BackgroundCssClass="modal" 
            DropShadow="True" 
            PopupControlID="programmaticPopup" 
            PopupDragHandleControlID="programmaticPopupDragHandle"
            BehaviorID="programmaticModalPopupBehavior">
            </ajaxToolkit:ModalPopupExtender> 
                <asp:Panel id="programmaticPopup" runat="server" 
                    Width="404px" Height="211px" 
                    CssClass="ModalPanel2" BackColor="White">
                    <asp:Panel id="programmaticPopupDragHandle" runat="Server" Height="30" 
                        __designer:wfdid="w101" CssClass="BarTitleModal2" BackColor="#2174BC"><DIV style="PADDING-RIGHT: 5px; PADDING-LEFT: 5px; PADDING-BOTTOM: 5px; VERTICAL-ALIGN: middle; PADDING-TOP: 5px">
                            <asp:Label ID="Label15" runat="server" Font-Bold="True" ForeColor="White" 
                                Text="SIEGRE"></asp:Label>
                        </DIV></asp:Panel> <DIV style="TEXT-ALIGN: center"><BR /><asp:Image id="ImgRst" runat="server" ImageUrl="~/imagenes/error.png" __designer:wfdid="w102" Width="64px" Height="64px"></asp:Image><br /> <asp:Label id="MsgModalPanel" runat="server" Width="278px" Height="33px" __designer:wfdid="w103" Text="Mensaje de Salida"></asp:Label><BR /><BR />
                        <asp:Button ID="Button1" runat="server" Text="Aceptar" />
                        &nbsp;<BR /> <BR /></DIV><BR /></asp:Panel>
             <asp:Button ID="Button2" runat="server" style="display:none" />
             <ajaxToolkit:ModalPopupExtender 
                    id="ModalPopupExtender1" 
                    runat="server" __designer:wfdid="w92" 
                    TargetControlID="Button2" 
                    BackgroundCssClass="modal" 
                    CancelControlID="BCancel" 
                    DropShadow="true" 
                    PopupControlID="Panel1" 
                    PopupDragHandleControlID="Panel2">
             </ajaxToolkit:ModalPopupExtender>
             <asp:Button ID="Button3" runat="server" style="display:none" />
                <asp:Panel 
                id="Panel1" 
                runat="server" 
                Width="410px" 
                Height="191px" 
                __designer:wfdid="w93" 
                CssClass="ModalPanel2" BackColor="White">
                    <asp:Panel 
                    id="Panel2" 
                    runat="server" 
                    Height="30px"
                    __designer:wfdid="w94" 
                    CssClass="BarTitleModal2" 
                    BackColor="#2174BC"> 
                    <div style="padding:5px; vertical-align: middle;">
                        <asp:Label ID="Label16" runat="server" Font-Bold="True" ForeColor="White" 
                            Text="SIEGRE"></asp:Label>
                    </div>
                    </asp:Panel> &nbsp; &nbsp;&nbsp; <BR />
                    <BR /><DIV style="TEXT-ALIGN: center">
                    <asp:Label id="Label11" runat="server" Width="315px" Height="51px" 
                            __designer:wfdid="w95">Realmente desea eliminar el registro?</asp:Label><BR />
                        <BR />
                        <br />
                    <asp:Button id="Button4" runat="server" Width="62px" __designer:wfdid="w96" 
                            Text="Si"></asp:Button> &nbsp; 
                    <asp:Button id="BCancel" runat="server" Width="62px" __designer:wfdid="w97" 
                            Text="No"></asp:Button> <BR /><BR /></DIV>
                    </asp:Panel>
            </ContentTemplate>
        </asp:UpdatePanel>
</asp:Content>

